package org.ds.blog.model;

import lombok.Data;
import lombok.Getter;
import lombok.Setter;

/**
 * @author glx
 */

@Getter
public enum CustomCode {
    /**
     * SUCCESS 成功状态码
     */
    SUCCESS("00000","成功"),

    FAILED("10000","失败"),

    USER_EXIST("10001","用户已存在"),
    USER_NOT_EXIST("10002","用户不存在"),

    VALIDATE_ERROR("10005","参数校验错误");
    private String code;
    private String message;

    CustomCode(String code, String message) {
        this.code = code;
        this.message = message;
    }
    public String getCode(){
        return code;
    }
    public String getMessage(){
        return message;
    }
}
